/*
 * Copyright (c) 2006-2020, RT-Thread Development Team
 *
 * SPDX-License-Identifier: Apache-2.0
 *
 * Change Logs:
 * Date           Author       Notes
 * 2020-11-24     XiaoYi       the first version
 */
#ifndef __DRV_USART_H_
#define __DRV_USART_H_

#include "drv_common.h"

extern UART_HandleTypeDef uart_handle_co2;   // UART2
extern UART_HandleTypeDef uart_handle_cat1; // UART3

int drv_usart_init(int index);

int drv_usart_send_bytes(int index, uint8_t *data, uint8_t len);

int drv_usart_recv_bytes(int index, uint8_t *data, uint8_t len);

int drv_usart_recv_bytes_IT(int index, uint8_t *data, uint8_t len);

#endif /* __DRV_USART_H_ */

